/**     
 * @Title: Message.java   
 * @Package me.springboot.message   
 * @Description: TODO
 * @author weiwei 
 * @date 2017年9月1日 上午9:42:04   
 * @version V1.0     
 */
package me.springboot.message;

/**
 * @ClassName: Message
 * @Description: 信息管理类
 * @author weiwei
 * @date 2017年9月1日 上午9:42:04
 * 
 */
public class Message {

	private int code;

	private String message;

	private Object content;

	public Message() {

	}

	public Message(int code, String message) {
		this.code = code;
		this.message = message;
	}

	public Message(int code, String message, Object content) {
		this.code = code;
		this.message = message;
		this.content = content;
	}

	public void setMsg(int code, String message) {
		this.code = code;
		this.message = message;
		this.content = "no content";
	}

	public void setMsg(int code, String message, Object content) {
		this.code = code;
		this.message = message;
		this.content = content;
	}

	/**
	 * @return the code
	 */
	public int getCode() {
		return code;
	}

	/**
	 * @param code
	 *            the code to set
	 */
	public void setCode(int code) {
		this.code = code;
	}

	/**
	 * @return the message
	 */
	public String getMessage() {
		return message;
	}

	/**
	 * @param message
	 *            the message to set
	 */
	public void setMessage(String message) {
		this.message = message;
	}

	/**
	 * @return the content
	 */
	public Object getContent() {
		return content;
	}

	/**
	 * @param content
	 *            the content to set
	 */
	public void setContent(Object content) {
		this.content = content;
	}

	@Override
	public String toString() {
		return "Message [code=" + code + ", message=" + message + ", content=" + content + "]";
	}
}
